#include <QApplication>
#include <QDirModel>
#include <QTreeView>
#include <QListView>
#include <QTableView>
#include <QSplitter>
#include <QtGui>

int main(int argc, char *argv[])
{
	QApplication app(argc, argv);
	
	QStringList str;
	str<<"11"<<"22"<<"33"<<"44";

	//model
	QStringListModel *model = new QStringListModel(str);
	//view
	QListView list;
	QTreeView tree;
	QTableView table;

	list.setModel(model);
	table.setModel(model);
	tree.setModel(model);

	QSplitter *splitter = new QSplitter();
	splitter->setOrientation(Qt::Vertical);
	splitter->addWidget(&list);
	splitter->addWidget(&table);
	splitter->addWidget(&tree);
	splitter->show();

	QModelIndex ind = model->index(1,1);
	QVariant value = model->data(ind, Qt::DisplayRole);
	qDebug()<<value;

	return app.exec();
}
